/**
 * kl yy-ds @2021
 */
package com.cxps.server;

import com.cxps.cloud.message.ApiResponse;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * 测试类
 * @author YouCai.Liu
 * @since 2021/10/18
 * ...
 */
@RestController
public class TestController {

    @GetMapping("/test")
    public String test(@RequestParam(value = "name", defaultValue = "World") String name) {
        return String.format("Hello %s!", name);
    }

    @GetMapping("/result")
    public ApiResponse result(@RequestParam(value = "name", defaultValue = "World") String name) {
        return ApiResponse.fireSuccess();
    }

}
